
#include "auto_ptr.h"
#include <iostream>
#include <assert.h>

class A
{
public:
	A(){}
	~A(){}
	void Hello()
	{
		std::cout << "Hello Smart Pointer" << std::endl;
	}
};

int main()
{
	auto_ptr<A> pA(new A());
	pA->Hello();

	auto_ptr<A> pB;
	pB = pA;
	assert(pA.get() == 0);
	assert(pB.get() != 0);
	pB->Hello();

	return 0;
}


